PATHMac OS 8 Developer Documentation > Operating System Services > Multiprocessing Services >

Adding Multitasking Capability to Applications Using Multiprocessing Services

   

Memory Allocation Option Constants

When calling the MPAllocateAligned function, you can specify optional actions by passing a constant of type OptionBits in the options parameter.

enum {
    /* Values for the options parameter to MPAllocateAligned.*/
    kMPAllocateClearMask    = 0x0001,
    kMPAllocateGloballyMask = 0x0002,
    kMPAllocateResidentMask = 0x0004,
    kMPAllocateNoGrowthMask = 0x0010
    };

Constant Descriptions

kMPAllocateClearMask
Zero out the allocated memory block.
kMPAllocateGloballyMask
Allocate memory from in memory space that is visible to all processes. Note that such globally-allocated space is not automatically reclaimed when the allocating process terminates. By default, MPAllocateAligned allocates memory from process-specific (that is, not global) memory.
kMPAllocateResidentMask
Allocate memory from resident memory only (that is, the allocated memory is not pageable).
kMPAllocateNoGrowthMask
Do not attempt to grow the pool of available memory. Specifying this option is useful, as attempting to grow memory may cause your task to block until such memory becomes available.
VERSION NOTES

Introduced with Multiprocessing Services 2.0.


© 1999 Apple Computer, Inc. – (Last Updated 07 May 99)